The present invention relates to a method of position recognition for use in automatization of assembling processes and the like in factories.
In the assembling processes in recent years, assembling robots have been employed to do assembling work through steps of recognizing positions of components to be assembled by a visual recognition apparatus and correcting their positions and attitudes. For example, at a component supply unit such as a tray, the assembling robot first recognizes and grips positions and attitudes of components to be assembled, and rotates and corrects their attitudes to achieve the assembly. Robots for screwing work carry out the work by gripping a screw, recognizing the position of the tapped hole, and correcting the position.
Various methods are available for the above-described position recognition. A prior art example of the method for position recognition is described with reference to FIGS. 8A-8B.
The prior art example is such that an image picked from an object by an image pickup device is scanned with a template pattern, and the template pattern is overlapped on the image of the object so that the position of the object is recognized. Referring to FIGS. 8A-8B, reference numeral 102 denotes an image surface picked up by the image pickup device, and 101 denotes an image of the object within the image surface. Reference numeral 103 denotes the template pattern having the same shape as that of the image of the object.
For recognition of the position of the image 101 of the object, while the template pattern 103 is moved little by little to scan the image surface 102 on which the image 101 of the object is present, product-sum operation of the template pattern 103 and the image surface 102 is performed so that gray-level correlation values are calculated. Thus, a position where the gray-level correlation value becomes a maximum is detected, and the detected position is recognized as the position of the object.
In the above-described prior art example, if the object is maintained in the same direction at all times, one template pattern 103 will do for recognition of the position of the object. However, if the object rotates or holds a different attitude such that the positional relationship between the image pickup device and the object is changed and therefore the object becomes different in the way how it is viewed from the image pickup device, it is necessary to previously prepare a plurality of template patterns 103 matching the different ways how the object is viewed, where if one template pattern 103 cannot serve to obtain gray-level correlation values more than a certain level, scanning would need to be repeated with the template pattern 103 replaced by another until the maximum gray-level correlation value is obtained. This would result in an excess of practicable processing time, which is a problem.
Also, when an image of the object is picked up by reflective illumination, variation in the positional relationship between the reflective normal line from the object and the optical axis of the image pickup device would cause the object to be brightened or darkened. As a result, if the illumination cannot be maintained in a constant direction, it becomes difficult to recognize the position of the object by the maximum gray-level correlation value, as another problem.